1. Field of the Invention
This invention relates to computer networks and file storage systems. More particularly, the invention relates to a system and method for pre-allocating replicas for a distributed file sharing system.
2. Description of the Related Art
Computer networks are important for many different applications. One important type of networking is referred to as peer-to-peer or P2P networking. As used herein, a peer-to-peer network is generally used to describe a decentralized network of peer nodes where each node may have similar capabilities and/or responsibilities. Participating peer nodes in a P2P network may communicate directly with each other. Work may be done and information may be shared through interaction among the peers. In addition, in a P2P network, a given peer node may be equally capable of serving as either a client or a server for another peer node.
A peer-to-peer network may be created to fulfill some specific need, or it may be created as a general-purpose network. Some P2P networks are created to deliver one type of service and thus typically run one application. For example, Napster was created to enable users to share music files. Other P2P networks are intended as general purpose networks which may support a large variety of applications. Any of various kinds of distributed applications may execute on a P2P network. Exemplary peer-to-peer applications include file sharing, messaging applications, distributed processing, etc.
A peer-to-peer network may be especially useful for applications which utilize distributed or shared data, in part because the reliance on centralized servers to access data can be reduced or eliminated. In particular, it may be desirable to implement a distributed file sharing system using a P2P network.
In some distributed file sharing systems, files may be replicated on multiple nodes in the system. In some systems, creating a new file may involve creating a plurality of replicas for the file on a plurality of nodes. For example, each file may initially be created with multiple replicas for various reasons, e.g., to increase the availability of the file in the event of node failure. Thus, file creation may involve several operations, such as selecting the nodes on which to create the replicas, creating the new replicas on each of the selected nodes, and linking the replicas together or publishing or storing information to enable nodes to access the replicas. If these operations are performed synchronously at the time when a client application requests the new file to be created, the client application may experience high latencies for the data object creation operation. It would be desirable to decrease the latency experienced by the client application.